package com.java.dao;

import java.sql.Connection;
import java.util.ArrayList;
import java.util.HashMap;

import com.java.util.DaoUtils;

public class Com0101lp02Dao extends CommonDao{
	public ArrayList execute(HashMap requestMap,Connection con) {

		ArrayList return_List = new ArrayList();
		ArrayList list = new ArrayList();
		try {

			String queryStr = "call com_com0101p02List_1(?,?,?,?)";

			String param[] = new String[4];
			param[0] = (String) requestMap.get("ent_id");
			param[1] = (String) requestMap.get("start_dt");
			param[2] = (String) requestMap.get("close_dt");
			param[3] = (String) requestMap.get("user_id");
			
			
			list = DaoUtils.select(con, queryStr, param);
			return_List.add(list);
			
			 
			queryStr = "call com_com0101p02List_2(?, ?, ?, ?)";
			
			param = new String[4];
			param[0] = (String) requestMap.get("ent_id");
			param[1] = (String) requestMap.get("start_dt");
			param[2] = (String) requestMap.get("close_dt");	
			param[3] = (String) requestMap.get("user_id");
			
			list = DaoUtils.select(con, queryStr, param);
			return_List.add(list);
			
			

		} catch (Exception ee) {
			ee.printStackTrace();
		}finally {
			try{
				if (con!=null) con.setAutoCommit(true);
				if (con!=null) con.close();
			}catch(Exception ee){}
		}
		return return_List;
	}

}
